extends layout

block content
    h1= title
    h1 ID: #{bookInstance._id}
    p #[strong Title:]
        a(href=bookInstance.book.url) #{bookInstance.book.title}
    p #[strong imprint] #{bookInstance.imprint}
    p #[strong 书本状态：]
        if bookInstance.status === '可供借阅'
            p.text-success #{bookInstance.status}
        else if bookInstance.status === '馆藏维护'
            p.text-danger #{bookInstance.status}
        else
            p.text-warning #{bookInstance.status}

    if bookInstance.status !== '可供借阅'
        p #[strong 归还日期：] #{bookInstance.due_back_formatted}
    p
        a(href=bookInstance.url+'/update') 编辑当前条目
    div
        form(method='post' action=bookInstance.url+'/delete')
            button.btn.btn-primary(type='submit') 删除当前条目

